"""author: wenyao
   data: 2021/12/14
   project: cjh
"""
#抽象基类  定义了接口规范，子类必须实现父类里的抽象方法
#抽象基类不能实例化   Animal不能实例化
from abc import ABC, abstractmethod
class Animal(ABC):
    @abstractmethod
    def eat(self):
        pass

    def drink(self):
        pass
class Dog(Animal):  #子类必须实现父类里的抽象方法
    def eat(self):
        pass

dog = Dog()
# a = Animal()